﻿@{
    Layout = null;
}
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>登录</title>
    <!--jQuery-->
    <script src="@Url.Content("~/scripts/jquery-1.5.1.js")" type="text/javascript"></script>
    <script src="@Url.Content("~/Scripts/jquery.validate.js")" type="text/javascript"></script>
    <script src="@Url.Content("~/Scripts/jquery.qtip.js")" type="text/javascript"></script>
    <!--css-->
    <link rel="stylesheet" href="/assets/css/reset.css" type="text/css" media="screen" />
    <link rel="stylesheet" href="/assets/css/main.css" type="text/css" media="screen" />
    <link rel="stylesheet" href="/assets/css/jquery.qtip.css" type="text/css" media="screen" />
    <script type="text/javascript">
        var opt = {
            //errorElement: "br",
            rules: {
                username: { required: true, minlength: 3 },
                password: { required: true, minlength: 6 }
            },
            messages: {
                username: { required: "用户名不能为空", minlength: "长度不能小于3" },
                password: { required: "密码不能为空", minlength: "密码长度不能小于6" }
            },
            errorPlacement: function (error, element) {
                $(element).qtip({
                    show: { event: false, ready: true },
                    position: { my: "top center", at: "bottom center" },
                    content: { text: error }
                });
            }
        };
        $(document).ready(function () {
            $("#form1").validate(opt);
        });
    </script>
</head>
<body id="b_login">
    <div id="header">
        <div id="logo">
            <h1 id="header_broomcupboard">
                <span class="logonew">例例生辉</span>
            </h1>
            <h4 id="header_strapline">
                &nbsp;&nbsp;&nbsp;胰岛素强化治疗优秀病例征集项目</h4>
        </div>
    </div>
    @*    @using (Html.BeginForm("index", "login", FormMethod.Post, new { @class = "login_form", id = "form1" }))
    {*@
    <form action="/login/index" method="post" class="login_form" id="form1">
    <fieldset>
        @if (ViewBag.HasError != null)
        {
            <div class="notification error">
                <a href="#" class="close" title="关闭">关闭</a> <em>
                    <img src="/assets/img/icons/cross_circle.png" alt="" />
                    <span id="spanerror">账号或密码错误</span></em>
            </div>
        }
        <label for="username" class="label2">
            <span>账号</span>
            @Html.TextBox("username")
        </label>
        <!--/end .label2-->
        <label for="password" class="label2">
            <span>密码</span>
            @Html.Password("password")
        </label>
        <!--/end .label2-->
        <!--bulletproof button : <button> version based on the <a> of Cameron Moll : http://www.cameronmoll.com/  -->
        <div class="button">
            <div class="btn-inner">
                <span><em>
                    <button type="submit">
                        <img src="/assets/img/icons/lock.png" alt="" />登 录</button>
                </em></span>
            </div>
        </div>
    </fieldset>
    </form>
    @*}*@
</body>
</html>
